package com.homedo.microservice.wechat.personal.secretary.entity;

import lombok.Data;

@Data
public class Biz implements Comparable<Biz> {
    private String name;
    private String code;
    private float sort;

    private PersonalBotBiz botBiz;

    public Biz(String name, String code, float sort) {
        this.name = name;
        this.code = code;
        this.sort = sort;
    }

    public Biz(String name, String code, float sort, PersonalBotBiz botBiz) {
        this.name = name;
        this.code = code;
        this.sort = sort;
        this.botBiz = botBiz;
    }

    @Override
    public int compareTo(Biz o) {
        return Float.compare(this.sort, o.sort);
    }

    protected void dealBiz() {
        throw new RuntimeException("不能处理业务");
    }
}
